package com.ywdnf.gomoku.util;

/**
 * 常量
 *
 * @author lss
 * @date 2019-06-26, Wed
 */
public class Const {


  public static final String HALF_HENG = "-";

  /**
   * 默认用户昵称前缀，需加随机 USER_ID_LEN_WITHOUT_PREFIX 位ID
   */
  public static final String DEFAULT_NICK_PREFIX = "临时用户";

  public static final String[] NICK_ARR = {
      "置身森林深处",
      "与自然的交融",
      "阳光穿过了树叶之间的缝隙",
      "像是一条梦幻般的路",
      "问好了路，走着走着，又忘了",
      "在不完美之中寻找美好",
      "想念却又可望不可及",
      "冬天壁炉升起的烟火",
      "山山而川",
      "清清落落",
      "未见终点，也未见恩典",
      "生生不息",
      "快点晴朗起来",
      "万水千山走遍",
      "心慢慢蒙起了灰",
      "雾中有阳光",
      "槐序十七",
      "不是山谷",
  };

  /**
   * 默认游戏房间前缀，需加随机 GAME_ID_LEN_WITHOUT_PREFIX 位ID
   */
  public static final String DEFAULT_GAME_NICK_PREFIX = "欢乐五子棋 :-) ";

  /**
   * 用户ID前缀，需加随机ID
   */
  public static final String USER_ID_PREFIX = "USER";

  /**
   * 用户id长度，去除前缀
   */
  public static final int USER_ID_LEN_WITHOUT_PREFIX = 8;

  /**
   * 游戏ID前缀，需加随机ID
   */
  public static final String GAME_ID_PREFIX = "GOMOKU";

  /**
   * 游戏id长度，去除前缀
   */
  public static final int GAME_ID_LEN_WITHOUT_PREFIX = 6;


  /**
   * session中用户id字段
   */
  public static final String USER_SESSION_ATTR_KEY = "UID";

  public static final String USER_COOKIE_ATTR_KEY = "UID";


  public static final String PARAM_USER_ID_IN_URL = "userId";
  public static final String PARAM_GAME_ID_IN_URL = "gameId";


  public static final int GOMOKU_LAYOUT_ROW_COUNT = 19;
  public static final int GOMOKU_LAYOUT_COL_COUNT = 19;


  /**
   * 单回合获胜奖励积分
   */
  public static final int WIN_AWARD_INTEGRAL = 100000;

  /**
   * 给自己加积分
   */
  public static final String BACK_DOOR_1 = "ADD MY INTEGRAL";

  /**
   * 最大连续先手次数
   */
  public static final int MAX_CONTINUE_FIRST = 2;

}
